package com.easylinkin.linkappapi.lobar.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.easylinkin.linkappapi.common.model.RequestModel;
import com.easylinkin.linkappapi.lobar.dto.GroupDTO;
import com.easylinkin.linkappapi.lobar.dto.excel.ExcelResultDTO;
import com.easylinkin.linkappapi.lobar.entity.Group;
import com.baomidou.mybatisplus.extension.service.IService;
import com.easylinkin.linkappapi.lobar.vo.LaborCompanyGroupVo;
import java.util.concurrent.ExecutionException;
import org.springframework.web.multipart.MultipartFile;
import site.morn.rest.RestMessage;

import java.util.Set;

/**
 * <p>
 * 闸机表 服务类
 * </p>
 *
 * @author kanyuanfeng
 * @since 2022-04-13
 */
public interface GroupService extends IService<Group> {

  IPage<GroupDTO> queryListByPage(RequestModel<GroupDTO> requestModel);

  /**
   * 增加
   * @param Group
   */
  void insert(Group Group);

  /**
   * 根据id编辑
   * @param Group
   */
  void updateOne(Group Group);

  /**
   * @Description: 删除班组（包含批量删除）
   * @author kan yuanfeng
   * @date 2020/11/04 11:42
   */
  void delBatch(Set<String> ids);

  /**
   * @Description: 进退场
   * @author kan yuanfeng
   * @date 2020/11/04 11:42
   */
  void updateStatus(Group group);

  /**
   * 分包单位班组树形数据
   *
   * @param laborCompanyGroupVo 条件对象vo
   * @return 统一出参
   */
    RestMessage subOrgGroupTree(LaborCompanyGroupVo laborCompanyGroupVo);

    ExcelResultDTO importExcel(MultipartFile file, String tenantId,Integer type)
        throws ExecutionException, InterruptedException, Exception;
}
